<template>
  <div>
    <router-view></router-view>
    <van-tabbar v-model="active" route>
      <van-tabbar-item to="/home/index">
        <span>首页</span>
        <template #icon="props">
          <img v-show="!props.active" src="@/assets/tabbar/shouye0.png" />
          <img v-show="props.active" src="@/assets/tabbar/shouye2.png" />
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/home/circle">
        <span>圈子</span>
        <template #icon="props">
          <img v-show="!props.active" src="@/assets/tabbar/quanzi0.png" />
          <img v-show="props.active" src="@/assets/tabbar/quanzi2.png" />
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/home/shopping">
        <span>商城</span>
        <template #icon="props">
          <img v-show="!props.active" src="@/assets/tabbar/shangcheng0.png" />
          <img v-show="props.active" src="@/assets/tabbar/shangcheng2.png" />
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/home/me">
        <span>我的</span>
        <template #icon="props">
          <img v-show="!props.active" src="@/assets/tabbar/wode0.png" />
          <img v-show="props.active" src="@/assets/tabbar/wode2.png" /> </template></van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script setup>
import { ref } from "vue";
import { useStore } from "vuex";

const active = ref("/home/index");
// console.log("HomeView_active", active);
</script>

<style lang="scss" scoped></style>
